//
// Created by wxd on 2025/9/2.
//

#include "LightManager.h"

/*std::string LightManager::addLight(const BaseLight &light) {
    std::string traceId = light.getTraceId();
    m_LightMap.try_emplace(traceId, light.clone());
    return traceId;
}

BaseLight *LightManager::getLight(const std::string &lightId) {
    auto it = m_LightMap.find(lightId);
    return it != m_LightMap.end() ? it->second.get() : nullptr;
}

bool LightManager::contain(const std::string &lightId) {
    return m_LightMap.find(lightId) != m_LightMap.end();
}

bool LightManager::removeLight(const std::string &lightId) {
    if (const auto it = m_LightMap.find(lightId); it != m_LightMap.end()) {
        m_LightMap.erase(it);
        return true;
    }
    return false;
}

void LightManager::clear() {
    m_LightMap.clear();
}*/
